Repository navigation
Release 0.30.2: safer with crafted files, faster 3MF copies, Build plate in two columns - #87
Merged
Merged
Conversation
…lead PrintView3D - 3MF: a triangle that uses a vertex that does not exist is refused. The 3D engine does not check this itself, and such a file crashed the whole program. - glTF: data must lie inside its buffer. A crafted byteStride or count read whatever followed the buffer in memory, or crashed. Triangles must use existing vertices too. - Text from a file (title, description, object names, error texts) is shown as plain text in the Details and Objects boxes, their tooltips and the error messages. It was read as HTML, so a title like <img src=...> was carried out instead of shown. - Loading that never ended: a glTF node listed as its own child, or 3MF objects that contain themselves or place each other without end. Nodes are visited once; 3MF objects that contain themselves are skipped and a file may place 200,000 objects at most. The macOS Quick Look reader gets the same limit. A 3MF object placed many times is now read once instead of every time, which also makes projects with many copies of one object open faster.
Left: the plate itself (grid on/off, X/Y/Z axes, which plate, its size). Right: the grid's numbers and lines (numbers on/off, their spacing, the two line spacings). The box is half as tall, with room for more options. A window too narrow for both columns shows the right one under the left one instead of cutting it off, and Settings opens wide enough for the two columns when the screen allows it.
…ate in two columns
The Build plate box's two columns go under each other when the window is too narrow for both, which makes the Viewer page taller. Settings still chose its height for the two-column arrangement, so on a narrow screen the page got a scroll bar (the macOS test run, whose test screen is 800 px wide, caught it). The two-column box now reports its height for a given width, and when Settings opens it is fitted once to the real sizes, after the theme's fonts and paddings are applied: wide enough for the two columns and tall enough for the tallest page, as far as the screen allows.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Release 0.30.2. Merging publishes the release.
Fixed: files made to harm
Four ways a crafted file could misuse PrintView3D, found in a review of the code:
byteStrideorcountread whatever followed the buffer in memory, or crashed. Data must now lie inside its buffer, and glTF triangles must use existing vertices.Changed
Translations
Arabic and Dutch: the changelog sections (
CHANGELOG.ar.md,CHANGELOG.nl.md) are reviewed by @sevagjb. No texts in the program changed. Romanian shows this version in English until it is translated.Still to do before merging
Checked
Windows, Linux, macOS Apple silicon and macOS Intel build and pass their tests in CI, including the Quick Look (Swift) build. 824 tests pass, including new ones with crafted 3MF and glTF files (
tests/test_file_safety.py) and for the two-column layout (tests/test_viewer_settings_layout.py).The first CI run failed on macOS: on a screen too narrow for the two columns, Settings was not tall enough for the page. Fixed in the last commit; Settings is now fitted to its pages' real sizes when it opens.
Generated by Claude Code